public abstract class Duck {
	//属性, 策略接口
	FlyBehavior flyBehavior;
	public Duck() {	}
	public void fly() {
		//改进
		if(flyBehavior != null) {
			flyBehavior.fly();
		}
	}
	public void setFlyBehavior(FlyBehavior flyBehavior) {
		this.flyBehavior = flyBehavior;
	}
}
